#pragma once

#include <xtd/type_traits.h>

namespace g3 {

template <class T> class basic_vector;
template <class T> class basic_matrix;
template <class T> class basic_smatrix;

} // g3

namespace p3d { struct scalar; }

namespace xtd {

template <class T>
struct type_traits< g3::basic_vector<T> > { 
	typedef typename type_traits<T>::accumulator_type accumulator_type;
	typedef typename type_traits<T>::real_type real_type;
	typedef T element_type;
};

template <class T>
struct type_traits< g3::basic_matrix<T> > { 
	typedef typename type_traits<T>::accumulator_type accumulator_type;
	typedef typename type_traits<T>::real_type real_type;
	typedef T element_type;
};

template <class T>
struct type_traits< g3::basic_smatrix<T> > { 
	typedef typename type_traits<T>::accumulator_type accumulator_type;
	typedef typename type_traits<T>::real_type real_type;
	typedef T element_type;
};

template <>
struct type_traits<p3d::scalar> { 
	typedef type_traits<float>::accumulator_type accumulator_type;
	typedef float real_type;
	typedef float element_type;
};

} // xtd

